﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;

namespace WPFSample.DiagonalizeTheButtonsSample
{
    class DiagonalizeTheButtons : Window
    {
        public DiagonalizeTheButtons()
        {
            this.Title = "Diagonalize the Buttons";

            DiagonalPanel pnl = new DiagonalPanel();
            pnl.Background = Brushes.AliceBlue;
            this.Content = pnl;

            Random rand = new Random();
            for (int i = 0; i < 5; i++)
            {
                Button btn = new Button();
                btn.Content = "Button Number " + (i + 1);
                btn.FontSize += rand.Next(20);
                pnl.Add(btn);
            }
        }
    }
}
